package com.titaniue.java;

import org.apache.commons.io.FileUtils;
import org.junit.Test;

import java.io.File;
import java.io.IOException;

/**
 *@program: JavaSenior
 *@description:
 *@author: renfei.huang
 *@create: 2021-10-18 12:25
 */
public class FileUtilsTest {


    //使用工具类复制文件
    @Test
    public  void test(){

        File srcFile = new File("彼岸图网.jpg");
        File destFile = new File("彼岸图网3.jpg");

        try {
            FileUtils.copyFile(srcFile,destFile);
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}
